import { get, post, put } from '../request'

// 订单相关接口
export const orderApi = {
  //订单相关
  queryOrderList: (params) => post('/cake-service/mini-program/order/list',params),
  updateOrderStatus: (params) => post('/cake-service/mini-program/order/updateOrderStatus',params),
  create: (data) => post('/order/create', data),
  getList: (params) => get('/order/list', params),
  getDetail: (id) => get(`/order/detail/${id}`),
  cancel: (id) => put(`/order/${id}/cancel`),
  pay: (id, data) => post(`/order/${id}/pay`, data)
}

export default orderApi 